package site.beanyon.now.model.po;

import java.util.Date;

/**
 * 时间区间持久化描述类
 */
public class TimeSpanPO {
    /**
     * 主键id
     */
    private Integer id;

    /**
     * 开始时间
     */
    private Date startTime;

    /**
     * 结束时间
     */
    private Date endTime;

    /**
     * 所属卡片id
     */
    private Integer cardId;

    public TimeSpanPO(Date startTime, Date endTime, Integer cardId) {
        this.startTime = startTime;
        this.endTime = endTime;
        this.cardId = cardId;
    }

    public TimeSpanPO(Integer id, Date startTime, Date endTime, Integer cardId) {
        this.id = id;
        this.startTime = startTime;
        this.endTime = endTime;
        this.cardId = cardId;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Date getStartTime() {
        return startTime;
    }

    public void setStartTime(Date startTime) {
        this.startTime = startTime;
    }

    public Date getEndTime() {
        return endTime;
    }

    public void setEndTime(Date endTime) {
        this.endTime = endTime;
    }

    public Integer getCardId() {
        return cardId;
    }

    public void setCardId(Integer cardId) {
        this.cardId = cardId;
    }

    @Override
    public String toString() {
        return "TimeSpanPO{" +
                "id=" + id +
                ", startTime=" + startTime +
                ", endTime=" + endTime +
                ", cardId=" + cardId +
                '}';
    }
}
